<template>
  <xy-page>
    <div class="add-box">
      <el-button @click="createApp">新建应用</el-button>
    </div>
    <el-dialog title="创建应用" :visible.sync="showDialog">
      <el-form :model="submitParams" label-width="111px" inline>
        <div>
          <el-form-item label="名称">
            <el-input type="text" v-model="submitParams.name" style="width: 300px;"></el-input>
          </el-form-item>
        </div>
        <div>
          <el-form-item label="描述">
            <el-input type="textarea" v-model="submitParams.name" rows="4" style="width: 350px;"></el-input>
          </el-form-item>
        </div>
        <div>
          <el-form-item label="CNAME域名">
            <el-input type="text" v-model="submitParams.name" style="width: 300px;"></el-input>
          </el-form-item>
        </div>
        <div>
          <el-form-item label="额定并发">
            <el-input type="text" v-model="submitParams.name" style="width: 300px;"></el-input>
          </el-form-item>
        </div>
      </el-form>
      <div slot="footer" class="dialog-footer">
        <el-button type="primary" @click="confirm">保 存</el-button>
      </div>
    </el-dialog>
  </xy-page>
</template>

<script>
export default {
  data(){
    return {
      showDialog: false,
      submitParams:{
        name: ''
      }
    }
  },
  methods: {
    createApp(){
      this.showDialog = true
    },
    confirm(){
      this.showDialog = false
    }
  }
}
</script>

<style lang="scss" scoped>
.add-box{
  text-align: center;
  margin-top: 36vh;
}
</style>
